#!/usr/bin/python
# -*- coding: UTF-8 -*-

import tensorflow as tf

# tensorboard

a = tf.constant(2,name="a")
b = tf.constant(3,name="b")
x = tf.add(a,b,name="x")

with tf.Session() as sess:
    # 写到日志文件里
    writer = tf.summary.FileWriter('./graphs',sess.graph)
    print(sess.run(x))
    writer.close()
